import { createRouter, createWebHistory ,createWebHashHistory} from 'vue-router'
import startPages from '../views/startPages/route';
import errorPages from '../views/errorPages/route';
import mainPages from '../views/mainPages/route';

const routes = [
  {
    path:'/',
    redirect:{
      name:'login'
    }
  },
  ...startPages,
  ...errorPages,
  ...mainPages,
  {
    path:'/:pathMatch(.*)',
    redirect:{
      name:'notFound'
    }
  }
]

const router = createRouter({
  history: createWebHashHistory(process.env.BASE_URL),
  routes
})

export default router
